import time


# time模块：获取时间戳函数

def get_time(func):
    def inner():
        begin = time.time()
        func()
        end = time.time()
        print(f"被装饰的函数执行时间为{end - begin}")
        return end - begin

    return inner


@get_time
def func1():
    for i in range(1, 1000):
        print(i)


# func1()

list1 = []
for i in range(5):
    list1.append(func1())
else:
    print(list1)
